<?php 

Class ModuleResult extends CmsCustomModule {
	
	
    protected function __renderHead()
    {
		$top_size = $_GET['top_size'];
		$dateby = $_GET['dateby'];
		$month = $_GET['month'];
		$year = $_GET['year'];
		$startdate = $_GET['startdate'];
		$enddate = $_GET['enddate'];
		$age = $_GET['age'];
		$category = $_GET['category'];
		$gender = $_GET['gender'];
		$plan = $_GET['plan'];
		$package = $_GET['package'];
		$country = $_GET['country'];
		$sortby = $_GET['sortby'];
		$curr_datetime = date("Y-m-d H:i:s");
		
		$month = str_pad($month, 2, 0, STR_PAD_LEFT);
		$str_date = '';
		if($dateby == 'date'){
			$str_date = "{$startdate} to {$enddate}";
		}else{
			$str_date = "{$year} - {$month}";
		}
		
		$str_category = array();
		$category = explode(',', $category);
		foreach($category as $k){
			$str_category[] = AC::$category_list[$k];
		}
		$str_category = implode(',', $str_category);
		
		$str_age = array();
		$age = explode(',', $age);
		foreach($age as $k){
			$str_age[] = AC::$age_list[$k];
		}
		$str_age = implode(',', $str_age);
		
		$str_plan = '';
		if($plan=='free'){
			$str_plan = 'Free';
		}else{
			$tmp = explode(',', $package);
			$tmp2 = array();
			for($i=0,$ilen=count($tmp); $i< $ilen; $i++){
				$tmp2[] = AC::$video_plan_package[$tmp[$i]];
			}
			$tmp2 = implode(',', $tmp2);
			$str_plan = "Premium ({$tmp2})";
		}
		
		$str_gender = AC::$gender_list[$gender];
		
		$str_country = transCountry($country);
		
		$dateby = ucwords( strtolower($dateby));
		$sortby = ucwords( strtolower($sortby));
		$this->contents = <<<HTML
	<div id="result">
		<div class="hd">
			<div class="utility">
				<a href="#" class="print">Print</a> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
				Export to <a href="#">HTML</a>
			</div>
			<hr />
			<h1>Premium Video Viewing Report</h1>
			<div class="time">{$curr_datetime}</div><br />
			<div><b>By {$dateby}:</b> {$str_date}</div>
			<div><b>Top:</b> {$top_size}</div>
			<div><b>Video Category:</b> {$str_category}</div>
			<div><b>Subscription Plan:</b> {$str_plan}</div>
			<div><b>Gender:</b> {$str_gender}</div>
			<div><b>Age Group:</b> {$str_age}</div>
			<table class="nob"><tr><td valign="top" width="100"><b class="tit">Region/Country:</b>&nbsp;</td><td>{$str_country}</td></tr></table>
			<div><b>Sort By:</b> {$sortby}</div>
		</div>
		<div class="bd">

<table border="0" cellpadding="0" cellspacing="0">
	<!--- Gender & Age Group start -->
  <tbody><tr>
    <td colspan="4" class="tit"><div align="center" class="STYLE1">Total Summary</div></td>
  </tr>
  <tr class="weight">
    <td bgcolor="#cccccc"><strong>Video Title</strong></td>
    <td bgcolor="#cccccc" class="num"><strong>Frequency</strong></td>
    <td bgcolor="#cccccc" class="num"><strong>Duration</strong></td>
    <td bgcolor="#cccccc" class="num"><strong>Avg</strong></td>
  </tr>
  <tr>
      <td><span class="weight">Top1: VideoTitle1</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
      <td><span class="weight">Top2: VideoTitle2</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
   <tr>
      <td><span class="weight">Top3: VideoTitle3</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
   <tr>
      <td><span class="weight">Top4: VideoTitle4</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
   <tr>
      <td><span class="weight">Top5: VideoTitle5</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
   <tr>
      <td><span class="weight">Top6: VideoTitle6</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
    <tr>
      <td><span class="weight">Top7: VideoTitle7</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
     <tr>
      <td><span class="weight">Top8: VideoTitle8</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
     <tr>
      <td><span class="weight">Top9: VideoTitle9</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
     <tr>
      <td><span class="weight">Top10: VideoTitle10</span></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
</tbody></table>
		
		
		
<table border="0" cellpadding="0" cellspacing="0">
	<!--- Gender & Age Group start -->
  <tr>
    <td colspan="5" class="tit"><div align="center"><strong>Gender & Age Group </strong></div></td>
  </tr>
  <tr class="weight">
    <td width="">Category: Drama</td>
    <td width="">&nbsp;</td>
    <td width="">&nbsp;</td>
    <td width="">&nbsp;</td>
    <td width="">&nbsp;</td>
  </tr>
  <tr class="weight">
    <td bgcolor="#CCCCCC">Video Title</td>
    <td bgcolor="#CCCCCC">Group By</td>
    <td bgcolor="#CCCCCC" class="num">Frequency</td>
    <td bgcolor="#CCCCCC" class="num">Duration</td>
    <td bgcolor="#CCCCCC" class="num">Avg</td>
  </tr>
  <tr>
    <td colspan="5" class="weight">Top1: 六點半新聞報道</td>
  </tr>
  <tr class="weight">
	<td rowspan="19">&nbsp;</td>
    <td>M</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td>F</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="total">
    <td>Total</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
  <td colspan="5" valign="top">Top2: 星期二檔案</td>
  </tr>
  <tr class="weight">
	<td rowspan="19">&nbsp;</td>
    <td>M</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td>F</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
   </tr>
    <tr class="total">
    <td>Total</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
    <tr>
<td width="194"></td>
    <td width="195">&nbsp;</td>
    <td width="117">&nbsp;</td>
    <td width="95">&nbsp;</td>
    <td width="49">&nbsp;</td>
  </tr>
  <tr class="weight">
<td width="194">Category: Music</td>
    <td width="195">&nbsp;</td>
    <td width="117">&nbsp;</td>
    <td width="95">&nbsp;</td>
    <td width="49">&nbsp;</td>
  </tr>
  <tr class="weight">
    <td bgcolor="#CCCCCC">Video Title</td>
    <td bgcolor="#CCCCCC">Group By</td>
    <td bgcolor="#CCCCCC" class="num">Frequency</td>
    <td bgcolor="#CCCCCC" class="num">Duration</td>
    <td bgcolor="#CCCCCC" class="num">Avg</td>
  </tr>
  <tr>
    <td colspan="5" class="weight">Top1: 六點半新聞報道</td>
  </tr>
  <tr class="weight">
	<td rowspan="19">&nbsp;</td>
    <td>M</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td>F</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="total">
    <td>Total</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
  <td colspan="5">Top2: 星期二檔案</td>
  </tr>
  <tr class="weight">
	<td rowspan="19">&nbsp;</td>
    <td>M</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td>F</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;>20</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;21-25</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;26-30</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;31-35</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;36-40</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;41-45</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;46-50</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;50+</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
   </tr>
    <tr class="total">
    <td>Total</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
	</tr>
	<!--- Gender & Age Group end -->
	
	<!--- Region & Country start -->
  <tr class="weight">
    <td colspan="5" class="tit"><div align="center"><strong>Region & Country Group </strong></div></td>
  </tr>
  <tr class="weight">
    <td width="194">Category: Drama</td>
    <td width="195">&nbsp;</td>
    <td width="117">&nbsp;</td>
    <td width="95">&nbsp;</td>
    <td width="49">&nbsp;</td>
  </tr>
  <tr class="weight">
    <td bgcolor="#CCCCCC">Video Title</td>
    <td bgcolor="#CCCCCC">Group By</td>
    <td bgcolor="#CCCCCC" class="num">Frequency</td>
    <td bgcolor="#CCCCCC" class="num">Duration</td>
    <td bgcolor="#CCCCCC" class="num">Avg</td>
  </tr>
  <tr class="weight">
    <td colspan="5">Top1: 六點半新聞報道</td>
  </tr>
  <tr>
	<td rowspan="5">&nbsp;</td>
    <td><b>Asia (Some Countries)</b></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;China (CN)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Japan (JP)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Hong Kong (HK)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Taiwan (TW)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
  <td colspan="5" valign="top">Top2: 星期二檔案</td>
  </tr>
  <tr>
	<td rowspan="5">&nbsp;</td>
    <td><b>Asia (Some Countries)</b></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;China (CN)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Japan (JP)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Hong Kong (HK)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Taiwan (TW)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
	<td rowspan="6">&nbsp;</td>
    <td><b>Europe (Some Countries)</b></td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Albania (AL)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Belarus (BY)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Bulgaria (BG)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;Faroe Islands (FO)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td>Total</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
	<!--- Gender & Age Group end -->
	
	
	
	<!--- Subscription Plan  start -->
  <tr>
    <td colspan="5" class="tit"><div align="center"><strong>Subscription Plan  Group </strong></div></td>
  </tr>
  <tr class="weight">
    <td width="194">Category: Drama</td>
    <td width="195">&nbsp;</td>
    <td width="117">&nbsp;</td>
    <td width="95">&nbsp;</td>
    <td width="49">&nbsp;</td>
  </tr>
  <tr class="weight">
    <td bgcolor="#CCCCCC">Video Title</td>
    <td bgcolor="#CCCCCC">Group By</td>
    <td bgcolor="#CCCCCC" class="num">Frequency</td>
    <td bgcolor="#CCCCCC" class="num">Duration</td>
    <td bgcolor="#CCCCCC" class="num">Avg</td>
  </tr>
  <tr class="weight">
    <td colspan="5">Top1: 六點半新聞報道</td>
  </tr>
  <tr>
	<td rowspan="1">&nbsp;</td>
    <td>Free</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr class="weight">
    <td colspan="5">Top2: 六點半新聞報道</td>
  </tr>
  <tr class="weight">
	<td rowspan="7">&nbsp;</td>
    <td>Premium (All Subscription Plan)</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;24 hours</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;One week</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;One month</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;three months</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
  <tr>
    <td>&nbsp;&nbsp;&nbsp;&nbsp;One year</td>
    <td class="num">9,999,999</td>
    <td class="num">99h99m99s</td>
    <td class="num">0h9m99s</td>
  </tr>
	<!--- Subscription Plan  end -->
	
	
	
	
</table>
		</div>
	</div>
HTML;
    }
}
?>